<template>
    <div id="myLoading" v-show="show">
        <div>{{msg}}</div>
    </div>
</template>

<script>
export default {
    name: 'myLoading',
    props: {
        msg: String,
        show: Boolean
    },
    data() { 
        return {

        }
    },
    created() {

    },
    methods:{

    },
}
</script>

<style scoped lang="scss">
    #myLoading {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.2);
        display: flex;
        justify-content: center;
        align-items: center;
        div {
            max-width: 250px;
            // height: 150px;
            padding: 15px;
            background-color: rgba(0, 0, 0, .7);
            color: #fff;
            font-size: 18px;
            border-radius: 6px;
            line-height: 24px;
        }
    }
</style>